/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package earthdawnnet.util;

import java.awt.Image;
import java.io.IOException;
import java.net.URL;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.imageio.ImageIO;

/**
 *
 * @author Andreas Franek
 */
public class IconProvider
{
    private static Image icon = null;
    
    public static Image provide()
    {
        if(icon == null)
        {
            try
            {
                URL imageURL = ClassLoader.getSystemResource("earthdawnnet/resources/ED-icon.png");
                icon = ImageIO.read(imageURL);
            } catch (IOException ex)
            {
                Logger.getLogger(IconProvider.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
        return icon;
    }
    
}
